package com.magima.core.repository;

public class EncryptStringProcessor extends StringProcessor{
	protected String mSeed;
	public EncryptStringProcessor(String seed){
		super();
		mSeed = seed;
	}
	
	@Override
	public String encodeString(String str) {
		try {
			return EncryptUtil.encrypt(mSeed, str);
		} catch (Exception e) {
		}
		return null;
	}

	@Override
	public String decodeString(String str) {
		try {
			return EncryptUtil.decrypt(mSeed, str);
		} catch (Exception e) {
			e.printStackTrace();
		}
		return null;
	}

}
